<?php

namespace App\Http\Controllers;

use Illuminate\Http\Request;
use App\Http\Requests;
use App\Http\Controllers\Controller;
use Auth;
class AdminController extends Controller
{
    //
    public function __construct()
    {
    	echo '2332';die;
        $this -> middleware('auth:admin');
    }

    public function index()
    {
    	$admin = Auth::guard('admin')->user();
        echo '23';
        return view('admin.index');
        return '<p style="margin-left:200px;margin-top:100px;font-size:30px;color:blue;">你已经登录到了后台的首页了网址是xxx.com/admin.请您添加后台页面</p>';
    	
    }
    public function logout(){

        Auth::guard('admin')->logout();
        return Redirect('admin/login');
    }

}
